package innerdemo;

public class OuterClass {
    public static int demo3=33;
    public int demo4=44;
    //实例内部类
    class InnerClass{
        public int demo4=99;
        public static final int demo3=9;
        private int demo5=6;
        public void fun(){
            System.out.println(OuterClass.demo3);
            System.out.println(InnerClass.demo3);
            System.out.println(this.demo4);
            System.out.println(OuterClass.this.demo4);

        }
        public InnerClass(){
        }

    }

    public void fun(){
        InnerClass innerClass=new InnerClass();
    }
    public static void main(String[] args) {
        OuterClass outerClass=new OuterClass();
        OuterClass.InnerClass inner=outerClass.new InnerClass();
        System.out.println(inner.demo5);

    }
}
